<template>
	<view class="container">
		<view>
			<desc-wrapper :title="title" :desc="desc"></desc-wrapper>
			<z-card justifyContent="center">
				<view class="card-content-item">
					<view class="card-content_right flex-1">
						<view class="input-name-box">
							<input class="input-item" v-model="form.name" type="text" placeholder="请输入中文公司名" />
						</view>
					</view>
				</view>
			</z-card>
			<view class="bottom-btns">
				<view class="start-btn" @click="onClick_1">
					<text class="">立即打分</text>
				</view>
				<!-- <view class="contact-btn"></view> -->
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				title: '公司名打分',
				desc: '测试方法：输入您的公司全名，点击立即打分，并查看测算结果，请自行体会其中的吉凶指示。',
				form: {
					name: ''
				}
			};
		},
		onLoad() {

		},
		methods: {
			onClick_1() {
				let that = this;
				if (this.form.name == "") {
					uni.$u.toast("请输入中文公司名")
					return
				}
				uni.request({
					url: 'https://cs.appzdm.com:3000/Dafen/gongsi',
					method: 'POST',
					header: {
						'Content-Type': 'application/x-www-form-urlencoded'
					},
					data: that.form,
					success: (res) => {
						console.log(res, '@@@@@@@');
						uni.navigateTo({
							url: `/pages/companyname/detail?params=${JSON.stringify(res.data.data)}&name=${this.name}`
						})
					},
					fail: (error) => {
						console.error('Request Failed:', error);
					}
				});

			},
		},
	};
</script>
<style lang="scss" scoped>
	@import '../../static/style/common.scss';
	@import '../../static/style/marriage/index.scss';



	.radio-content {
		height: 40rpx;
		display: flex;
		align-items: center;
		margin-left: 20rpx;
	}

	.radio {
		width: 32rpx;
		height: 32rpx;
		border-radius: 50%;
		border: 2rpx solid #275515;
		display: flex;
		flex-direction: column;
		align-items: center;
		justify-content: center;
		margin: 0rpx 26rpx 0rpx 15rpx;
	}

	.radio-active {
		width: 18rpx;
		height: 18rpx;
		border-radius: 50%;
		background-color: #275515;
	}

	.radio-default {
		border: 2rpx solid #0fbda6;
	}

	.radio-right {
		margin-left: 26rpx;
	}

	/deep/ .uni-select {
		height: 56rpx;
		border: 1px solid #22630985;
	}

	.h200 {
		// height: 400rpx !important;
		min-height: 200rpx;
	}

	.box_1 {
		// width: auto !important;
		width: 80% !important;
		min-height: 64rpx;
		margin: 0 auto !important;
	}

	.input_1 {
		width: 100%;
	}

	.text_9 {
		height: 100%;
	}

	.page .group_1 .group_6 {
		padding-bottom: 500px;
	}
</style>